#ifndef USER_H
#define USER_H

#pragma once

#include <string>


class User {
public:
    enum UserStatus {
        OFFLINE,
        ONLINE,
        GAMEING,
    };

    static User& getInstance() {
        static User instance;
        return instance;
    }

    void setUserStatus(UserStatus status) {
        user_status_ = status;
    }

    User::UserStatus userStatus() const {
        return user_status_;
    }

    void setUid(uint32_t uid) {
        uid_ = uid;
    }

    uint32_t uid() const {
        return uid_;
    }

    void setUsername(const std::string &username) {
        username_ = username;
    }

    std::string username() const {
        return username_;
    }

private:
    User() = default;

    User(const User&) = delete;
    User& operator=(const User&) = delete;

    std::string username_;
    uint32_t uid_;
    enum UserStatus user_status_;
};

#endif // USER_H